Bug fix and improvement for ccpp_track_variables tool#451
Merged
Conversation
…es based on the xml file, output a list of schemes broken down by group (since groups can be called in different orders based on the logic in the host model)
…ation for multiple schemes, which led to incorrect duplication of schemes listed in output
gold2718
approved these changes
May 21, 2022
climbfuji
approved these changes
May 21, 2022
This was referenced May 23, 2022
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR changes the output slightly, so that the ordered lists of schemes are now broken down by group. This is done because different groups in a physics suite can be called in different orders depending on the logic of the host model, so only within each group is a set of schemes guaranteed to be called in that order.
This PR also fixes a bug in ccpp_track_variables.py that double-counted variables in schemes that have .meta files containing descriptions of more than one scheme.
Finally, this PR has some small improvements suggested by pylint, including removing trailing whitespace and trimming long lines.
Cases with partial matches or no matches found will not be affected by this change.
User interface changes?: No
Fixes: #450 (duplicate counting of schemes)
Testing:
Ran script against multiple xmls and confirmed new behavior removes duplicate schemes in script output. Also output is now broken down by group.
Here is an example of old output vs new:
Old
New